import request from '../utils/fetch'
export function getCourseList(data) {
  return request({
    url: '/admin/course/getCourseList',
    method: 'get',
    requestBody: 'null',
    loading: true,
    params: data
  })
}
export function getCourseContentList(data) {
  return request({
    url: '/admin/course/getCourseContentList',
    method: 'get',
    requestBody: 'null',
    loading: true,
    params: data
  })
}
export function addCourseContent(data) {
  return request({
    url: '/admin/course/addCourseContent',
    method: 'post',
    requestBody: 'null',
    loading: true,
    data: data
  })
}
export function editCourseContent(data) {
  return request({
    url: '/admin/course/editCourseContent',
    method: 'post',
    requestBody: 'null',
    loading: true,
    data: data
  })
}
export function addCourseAbout(data) {
  return request({
    url: '/admin/course/addCourseAbout',
    method: 'post',
    requestBody: 'null',
    loading: true,
    data: data
  })
}

export function getCourseAboutList(data) {
  return request({
    url: '/admin/course/getCourseAboutList',
    method: 'get',
    requestBody: 'null',
    loading: true,
    params: data
  })
}
export function delCourseAbout(data) {
  return request({
    url: '/admin/course/delCourseAbout',
    method: 'post',
    requestBody: 'query',
    loading: true,
    data: data
  })
}
export function delCourseContent(data) {
  return request({
    url: '/admin/course/delCourseContent',
    method: 'post',
    requestBody: 'query',
    loading: true,
    data: data
  })
}
export function enableCourseContent(data) {
  return request({
    url: '/admin/course/enableCourseContent',
    method: 'post',
    requestBody: 'query',
    loading: true,
    data: data
  })
}
export function enableCourse(data) {
  return request({
    url: '/admin/course/enableCourse',
    method: 'post',
    requestBody: 'query',
    loading: true,
    data: data
  })
}
export function addCourse(data) {
  return request({
    url: '/admin/course/addCourse',
    method: 'post',
    requestBody: 'null',
    loading: true,
    data: data
  })
}
export function editCourse(data) {
  return request({
    url: '/admin/course/editCourse',
    method: 'post',
    requestBody: 'query',
    loading: true,
    data: data
  })
}

export function getCourseErrorList(data) {
  return request({
    url: '/admin/courseerror/getCourseErrorList',
    method: 'get',
    requestBody: 'query',
    loading: true,
    params: data
  })
}
export function checkCourseError(data) {
  return request({
    url: '/admin/courseerror/checkCourseError',
    method: 'post',
    requestBody: 'body',
    loading: true,
    data: data
  })
}